Skip to content

fix: prevent parsing repository examples in code blocks#4

Merged
worlddriven[bot] merged 1 commit intoworlddriven:mainfrom
TooAngel:fix/parser-code-blocks-and-tests
Oct 25, 2025
Merged

fix: prevent parsing repository examples in code blocks#4
worlddriven[bot] merged 1 commit intoworlddriven:mainfrom
TooAngel:fix/parser-code-blocks-and-tests

Conversation

@TooAngel
Copy link
Copy Markdown
Contributor

Summary

Fixes a critical parser bug where repository definitions inside markdown code blocks were being treated as real repositories. This caused the sync script to create unintended repositories from documentation examples.

Changes

Parser Fix:

  • Added code block tracking to skip content between triple backticks
  • Prevents parsing of example repositories in documentation

Testing:

  • Added comprehensive unit test suite with 13 tests
  • All tests validate parser behavior including code block handling

CI Improvements:

  • New test workflow runs on all repos including forks
  • Restricted drift-detection and sync workflows to worlddriven org only
  • Forks can now run CI successfully without org secrets

Repository Definitions:

  • Added documentation repository
  • Added webapp repository

Verification

Parser now correctly returns only real repositories and ignores examples:

[
  {
    "name": "documentation",
    "description": "Core documentation repository for worlddriven project",
    "topics": ["documentation", "worlddriven"]
  },
  {
    "name": "webapp",
    "description": "Web application interface for worlddriven",
    "topics": ["webapp", "web", "frontend", "worlddriven"]
  }
]

All 13 unit tests pass.

@TooAngel TooAngel force-pushed the fix/parser-code-blocks-and-tests branch from af81e0c to 5108fed Compare October 21, 2025 17:51
@worlddriven
Copy link
Copy Markdown
Contributor

worlddriven bot commented Oct 21, 2025

🤖 Worlddriven Status

📊 Live Status Dashboard

🗓️ Merge Date: 2025-10-25 at 17:59:04 UTC (today)
📅 Started: 2025-10-21 at 17:59:04 UTC
Speed Factor: 0.40 (60% faster due to reviews)
Positive votes: 3/5 contribution weight (coefficient: 0.60)
📈 Base Merge Time: 10 days → Current: 4 days

🎯 Want to influence when this merges?

Your review matters! As a contributor to this project, your voice helps determine the merge timeline.

How to review:

  1. Check the changes
    Files changed

  2. Leave your review
    Review changes

Your options:

  • ✅ Agree & Speed Up: Approve Approving makes this merge faster
  • ❌ Disagree & Slow Down: Request changes Requesting changes delays the merge

💡 Pro tip: The more contributors who agree, the faster this gets merged!

📊 View detailed stats on the dashboard

📋 Recent Activity

2025-10-25, 18:52:44 - Pull request merged by worlddriven ✅


This comment is automatically updated by worlddriven

@TooAngel TooAngel force-pushed the fix/parser-code-blocks-and-tests branch 2 times, most recently from b0e7a34 to a91fc1b Compare October 21, 2025 17:57
The parser was incorrectly treating repository definitions inside
markdown code blocks as real repositories, causing the sync script
to create repositories from documentation examples.

Changes:
- Add code block tracking to parse-repositories.js
- Skip all content between triple backticks
- Add comprehensive unit test suite with 13 tests
- Add test workflow for CI that runs on all repos including forks
- Restrict drift-detection and sync workflows to worlddriven org only
- Add documentation and webapp repositories to REPOSITORIES.md

This ensures forks can run CI successfully without access to org secrets,
while the sync automation only runs in the main organization.
@TooAngel TooAngel force-pushed the fix/parser-code-blocks-and-tests branch from a91fc1b to 1bf8d0d Compare October 21, 2025 17:59
@worlddriven worlddriven bot merged commit 6cf04c3 into worlddriven:main Oct 25, 2025
3 checks passed
@TooAngel TooAngel deleted the fix/parser-code-blocks-and-tests branch October 26, 2025 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant